package com.shop.entity;

import com.baomidou.mybatisplus.extension.activerecord.Model;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

import java.util.Date;

/**
 * (MerchantGoods)表实体类
 *
 * @author makejava
 * @since 2020-11-21 10:31:04
 */
@Data
@ToString
@NoArgsConstructor
@AllArgsConstructor
public class MerchantGoods extends Model<MerchantGoods> {

    private Integer id;
    //商品名
    @NotEmpty(message = "商品还没有取名字^_^")
    private String goodsName;
    //类别
    @NotNull(message = "请选择类别")
    private Integer categoryId;
    //单位
    private String goodsUnit;
    //规格
    private String goodsSpecification;
    //零售价
    @NotNull(message = "请设置商品售价")
    private Double goodsSalePrice;
    //商品库存
    @NotNull(message = "商品还没有设置库存喔")
    private Integer inventory;
    //上下架状态
    private String goodsSellStatus;
    //审核状态
    private String goodsCheckStatus;
    //商品品牌
    private String goodsBrand;

    private Integer goodsWarningNum;

    private Integer createUserId;

    private Integer updateUserId;

    private String isDelete;

    private Date createTime;

    private Date updateTime;

    private String version;
    //商品详情
    private String goodsDetails;
    //商品展示图
    private String goodsImage;

    //后增字段
    private Integer cartCount;
    private String status;
    private String statusOne;
    private String statusTwo;
    private Integer merchantId;


    private String categoryName;//类别名
}
